package com.lzy.business.freemaker;

import com.jagregory.shiro.freemarker.ShiroTags;
import freemarker.template.TemplateException;
import org.springframework.web.servlet.view.freemarker.FreeMarkerConfigurer;

import java.io.IOException;

/**
 * Created with IntelliJ IDEA.
 * Description: lzy-product-coupon20180410
 *
 * @author: ellengou
 * @date: 2018-05-08 星期二
 * @time: 19:19
 */
public class FreemakerConfig extends FreeMarkerConfigurer {
    @Override
    public void afterPropertiesSet() throws IOException, TemplateException {
        super.afterPropertiesSet();
        this.getConfiguration().setSharedVariable("shiro", new ShiroTags());
    }
}
